
<%@ page import="rentadomus.House" %>
<!DOCTYPE html>
<html>
  <head>
    <meta name="layout" content="main">
  <g:set var="entityName" value="${message(code: 'house.label', default: 'House')}" />
  <title><g:message code="default.show.label" args="[entityName]" /></title>
</head>
<body>
  <a href="#show-house" class="skip" tabindex="-1"><g:message code="default.link.skip.label" default="Skip to content&hellip;"/></a>
  <div class="nav" role="navigation">
    <ul>
      <li><a class="home" href="${createLink(uri: '/')}"><g:message code="default.home.label"/></a></li>
    </ul>
  </div>
  <div id="show-house" class="content scaffold-show" role="main">
    <h1><g:message code="default.show.label" args="[entityName]" /></h1>
    <g:if test="${flash.message}">
      <div class="message" role="status">${flash.message}</div>
    </g:if>
    <ol class="property-list house">

      <div style="float:left;">
        <g:if test="${placeInstance.mainImage !=0}">
          <img class="normal" src="${createLink(controller:'UploadImage', action:'displayImage', id:(int)placeInstance.mainImage)}" />
        </g:if>
        <g:else>
          There is no image available.
        </g:else>

      </div>  

      <div >
        <g:if test="${placeInstance?.titlePlace}">
          <li class="fieldcontain">

            <b><span class="property-value" aria-labelledby="titlePlace-label"><g:fieldValue bean="${placeInstance}" field="titlePlace"/></span></b>

          </li>
        </g:if>


        <g:if test="${placeInstance?.rentPrice}">
          <li class="fieldcontain">


          <price><span class="property-value" aria-labelledby="rentPrice-label">$ <g:fieldValue bean="${placeInstance}" field="rentPrice"/></span></price>

          </li>
        </g:if>
      </div>

      <div style="clear:both;">

        <g:if test="${placeInstance?.idPerson}">
          <li class="fieldcontain">
            <span id="idPerson-label" class="property-label">Owner</span>

            <span class="property-value" aria-labelledby="idPerson-label">${placeInstance?.idPerson?.encodeAsHTML()}</span>

          </li>
        </g:if>

        <g:if test="${session.person}">
          <g:each in="${phones}" status="i" var="phone">
            <li class="fieldcontain">
              <span class="property-value" aria-labelledby="phone-label">${phone}</span>
            </li>
          </g:each>
        </g:if>

        <g:if test="${placeInstance?.description}">
          <li class="fieldcontain">
            <span id="description-label" class="property-label"><g:message code="place.description.label" default="Description" /></span>

            <span class="property-value" aria-labelledby="description-label"><g:fieldValue bean="${placeInstance}" field="description"/></span>

          </li>
        </g:if>  

        <g:if test="${placeInstance?.address}">
          <li class="fieldcontain">
            <span id="address-label" class="property-label"><g:message code="place.address.label" default="Address" /></span>

            <span class="property-value" aria-labelledby="address-label"><g:fieldValue bean="${placeInstance}" field="address"/></span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.neighborhood}">
          <li class="fieldcontain">
            <span id="neighborhood-label" class="property-label"><g:message code="place.neighborhood.label" default="Neighborhood" /></span>

            <span class="property-value" aria-labelledby="neighborhood-label"><g:fieldValue bean="${placeInstance}" field="neighborhood"/></span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.date}">
          <li class="fieldcontain">
            <span id="date-label" class="property-label"><g:message code="place.date.label" default="Date" /></span>

            <span class="property-value" aria-labelledby="date-label"><g:formatDate date="${placeInstance?.date}" /></span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.strata}">
          <li class="fieldcontain">
            <span id="strata-label" class="property-label"><g:message code="place.strata.label" default="Strata" /></span>

            <span class="property-value" aria-labelledby="strata-label"><g:fieldValue bean="${placeInstance}" field="strata"/></span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.area}">
          <li class="fieldcontain">
            <span id="area-label" class="property-label"><g:message code="place.area.label" default="Area" /></span>

            <span class="property-value" aria-labelledby="area-label"><g:fieldValue bean="${placeInstance}" field="area"/> m²</span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.cableTv}">
          <li class="fieldcontain">
            <span id="cableTv-label" class="property-label"><g:message code="place.cableTv.label" default="Cable Tv" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${placeInstance?.energy}">
          <li class="fieldcontain">
            <span id="energy-label" class="property-label"><g:message code="place.energy.label" default="Energy" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>

          </li>
        </g:if>

        <g:if test="${placeInstance?.gas}">
          <li class="fieldcontain">
            <span id="gas-label" class="property-label"><g:message code="place.gas.label" default="Gas" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${placeInstance?.phone}">
          <li class="fieldcontain">
            <span id="phone-label" class="property-label"><g:message code="place.phone.label" default="Phone" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${placeInstance?.water}">
          <li class="fieldcontain">
            <span id="water-label" class="property-label"><g:message code="place.water.label" default="Water" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${placeInstance?.wifi}">
          <li class="fieldcontain">
            <span id="wifi-label" class="property-label"><g:message code="place.wifi.label" default="Wifi" /></span>
            <span class="property-value" aria-labelledby="cableTv-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.furnished}">
          <li class="fieldcontain">
            <span id="furnished-label" class="property-label">Furnished</span>
            <span class="property-value" aria-labelledby="furnished-label">Yes</span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.bedrooms}">
          <li class="fieldcontain">
            <span id="bedrooms-label" class="property-label">Beedrooms</span>
            <span class="property-value" aria-labelledby="Beedrooms-label"><g:fieldValue bean="${dwellingInstance}" field="bedrooms"/></span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.baths}">
          <li class="fieldcontain">
            <span id="baths-label" class="property-label">Baths</span>
            <span class="property-value" aria-labelledby="baths-label"><g:fieldValue bean="${dwellingInstance}" field="baths"/></span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.parkingSlots}">
          <li class="fieldcontain">
            <span id="parkingSlots-label" class="property-label">Parking Slots</span>
            <span class="property-value" aria-labelledby="parkingSlots-label"><g:fieldValue bean="${dwellingInstance}" field="parkingSlots"/></span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.block}">
          <li class="fieldcontain">
            <span id="block-label" class="property-label">Block</span>
            <span class="property-value" aria-labelledby="block-label"><g:fieldValue bean="${dwellingInstance}" field="block"/></span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.interior}">
          <li class="fieldcontain">
            <span id="interior-label" class="property-label">Interior</span>
            <span class="property-value" aria-labelledby="interior-label"><g:fieldValue bean="${dwellingInstance}" field="interior"/></span>
          </li>
        </g:if>

        <g:if test="${dwellingInstance?.kitchenType}">
          <li class="fieldcontain">
            <span id="kitchenType-label" class="property-label">Kitchen Type</span>
            <span class="property-value" aria-labelledby="kitchenType-label"><g:fieldValue bean="${dwellingInstance}" field="kitchenType"/></span>
          </li>
        </g:if>        

        <g:if test="${houseInstance?.floors}">
          <li class="fieldcontain">
            <span id="floors-label" class="property-label"><g:message code="house.floors.label" default="Floors" /></span>

            <span class="property-value" aria-labelledby="floors-label"><g:fieldValue bean="${houseInstance}" field="floors"/></span>

          </li>
        </g:if>
      </div>
    </ol>
    <g:if test="${session.person && visible}">
      <g:form>
        <fieldset class="buttons">
          <g:hiddenField name="id" value="${houseInstance?.id}" />
          <g:link class="edit" action="edit" id="${houseInstance?.id}"><g:message code="default.button.edit.label" default="Edit" /></g:link>
          <g:actionSubmit class="delete" action="delete" value="${message(code: 'default.button.delete.label', default: 'Delete')}" onclick="return confirm('${message(code: 'default.button.delete.confirm.message', default: 'Are you sure?')}');" />
        </fieldset>
      </g:form>
    </g:if>
  </div>
</body>
</html>
